package com.ruoyi.thoroughfare.controller;

import com.ruoyi.thoroughfare.service.IAppShareService;
import com.ruoyi.thoroughfare.service.IAppUserService;
import com.ruoyi.common.core.web.controller.BaseController;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Controller;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.ui.Model;


/**
 * app注册控制器
 * 前端访问路由地址为:/app/register
 *
 * @author Zach
 * @date 2023-11-14
 */
@Validated
@RequiredArgsConstructor
@Controller
@RequestMapping("/register")
public class AppRegisterHtmlController extends BaseController {

    private final IAppShareService iAppShareService;
    private final IAppUserService iAppUserService;


    @GetMapping("/toRegister")
    public String toRegister(Model model,String phone,String code)
    {
        model.addAttribute("code",code);
        model.addAttribute("phone",phone);
        return "index";
    }
    @GetMapping("/toServer")
    public String toServer(Model model)
    {
        return "service_agreement";
    }

}
